<!DOCTYPE html><html lang="en" data-theme="light"><head><meta charset="UTF-8"><meta http-equiv="X-UA-Compatible" content="IE=edge"><meta name="viewport" content="width=device-width,initial-scale=1"><title>UML | Cying</title><meta name="keywords" content="Java"><meta name="author" content="Cying-承影"><meta name="copyright" content="Cying-承影"><meta name="format-detection" content="telephone=no"><meta name="theme-color" content="#ffffff"><meta name="description" content="一、Why UMLUML (Unified Modeling Language - 统一建模语言) ，是一种用来对软件密集系统进行 可视化建模 的语言，UML 的定义包括 UML 语义和 UML 表示法两个元素。 UML 的目标是以 面向对象图 的方式来描述任何类型的系统，具有很宽的应用领域，包含十种图 点击跳转至Wiki解释 二、What is UML Class DiagramClass Di">
<meta property="og:type" content="article">
<meta property="og:title" content="UML">
<meta property="og:url" content="http://cyingk.github.io/2020/02/26/UML/index.html">
<meta property="og:site_name" content="Cying">
<meta property="og:description" content="一、Why UMLUML (Unified Modeling Language - 统一建模语言) ，是一种用来对软件密集系统进行 可视化建模 的语言，UML 的定义包括 UML 语义和 UML 表示法两个元素。 UML 的目标是以 面向对象图 的方式来描述任何类型的系统，具有很宽的应用领域，包含十种图 点击跳转至Wiki解释 二、What is UML Class DiagramClass Di">
<meta property="og:locale" content="en_US">
<meta property="og:image" content="https://upload-images.jianshu.io/upload_images/5336514-985132f6977c5d33.png?imageMogr2/auto-orient/strip|imageView2/2/w/694/format/webp">
<meta property="article:published_time" content="2020-02-26T10:37:23.000Z">
<meta property="article:modified_time" content="2020-02-26T10:52:40.000Z">
<meta property="article:author" content="Cying-承影">
<meta property="article:tag" content="Java">
<meta name="twitter:card" content="summary">
<meta name="twitter:image" content="https://upload-images.jianshu.io/upload_images/5336514-985132f6977c5d33.png?imageMogr2/auto-orient/strip|imageView2/2/w/694/format/webp"><link rel="shortcut icon" href="/img/favicon.ico"><link rel="canonical" href="http://cyingk.github.io/2020/02/26/UML/"><link rel="preconnect" href="//cdn.jsdelivr.net"/><link rel="preconnect" href="//www.clarity.ms"/><link rel="preconnect" href="//busuanzi.ibruce.info"/><link rel="stylesheet" href="/css/index.css"><link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/@fortawesome/fontawesome-free/css/all.min.css" media="print" onload="this.media='all'"><link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/node-snackbar/dist/snackbar.min.css" media="print" onload="this.media='all'"><script>(function(c,l,a,r,i,t,y){
    c[a]=c[a]||function(){(c[a].q=c[a].q||[]).push(arguments)};
    t=l.createElement(r);t.async=1;t.src="https://www.clarity.ms/tag/"+i;
    y=l.getElementsByTagName(r)[0];y.parentNode.insertBefore(t,y);
})(window, document, "clarity", "script", "4zndahq92q");</script><script>const GLOBAL_CONFIG = { 
  root: '/',
  algolia: undefined,
  localSearch: undefined,
  translate: undefined,
  noticeOutdate: undefined,
  highlight: {"plugin":"highlighjs","highlightCopy":true,"highlightLang":true},
  copy: {
    success: 'Copy successfully',
    error: 'Copy error',
    noSupport: 'The browser does not support'
  },
  relativeDate: {
    homepage: false,
    post: false
  },
  runtime: 'days',
  date_suffix: {
    just: 'Just',
    min: 'minutes ago',
    hour: 'hours ago',
    day: 'days ago',
    month: 'months ago'
  },
  copyright: undefined,
  lightbox: 'fancybox',
  Snackbar: {"chs_to_cht":"Traditional Chinese Activated Manually","cht_to_chs":"Simplified Chinese Activated Manually","day_to_night":"Dark Mode Activated Manually","night_to_day":"Light Mode Activated Manually","bgLight":"#49b1f5","bgDark":"#121212","position":"bottom-left"},
  source: {
    jQuery: 'https://cdn.jsdelivr.net/npm/jquery@latest/dist/jquery.min.js',
    justifiedGallery: {
      js: 'https://cdn.jsdelivr.net/npm/justifiedGallery/dist/js/jquery.justifiedGallery.min.js',
      css: 'https://cdn.jsdelivr.net/npm/justifiedGallery/dist/css/justifiedGallery.min.css'
    },
    fancybox: {
      js: 'https://cdn.jsdelivr.net/npm/@fancyapps/fancybox@latest/dist/jquery.fancybox.min.js',
      css: 'https://cdn.jsdelivr.net/npm/@fancyapps/fancybox@latest/dist/jquery.fancybox.min.css'
    }
  },
  isPhotoFigcaption: true,
  islazyload: false,
  isanchor: false
};

const saveToLocal = {
  // ttl 單位是 天
  set: function setWithExpiry(key, value, ttl) {
    if (ttl === 0) return
    const now = new Date()
    const expiryDay = ttl * 86400000
    const item = {
      value: value,
      expiry: now.getTime() + expiryDay,
    }
    localStorage.setItem(key, JSON.stringify(item))
  },

  get: function getWithExpiry(key) {
    const itemStr = localStorage.getItem(key)

    if (!itemStr) {
      return undefined
    }
    const item = JSON.parse(itemStr)
    const now = new Date()

    if (now.getTime() > item.expiry) {
      localStorage.removeItem(key)
      return undefined
    }
    return item.value
  }
}

// https://stackoverflow.com/questions/16839698/jquery-getscript-alternative-in-native-javascript
const getScript = url => new Promise((resolve, reject) => {
  const script = document.createElement('script')
  script.src = url
  script.async = true
  script.onerror = reject
  script.onload = script.onreadystatechange = function() {
    const loadState = this.readyState
    if (loadState && loadState !== 'loaded' && loadState !== 'complete') return
    script.onload = script.onreadystatechange = null
    resolve()
  }
  document.head.appendChild(script)
})</script><script id="config_change">var GLOBAL_CONFIG_SITE = { 
  isPost: true,
  isHome: false,
  isHighlightShrink: false,
  isToc: true,
  postUpdate: '2020-02-26 18:52:40'
}</script><noscript><style type="text/css">
  #nav {
    opacity: 1
  }
  .justified-gallery img {
    opacity: 1
  }

  #recent-posts time,
  #post-meta time {
    display: inline !important
  }
</style></noscript><script>(function () {  window.activateDarkMode = function () {
    document.documentElement.setAttribute('data-theme', 'dark')
    if (document.querySelector('meta[name="theme-color"]') !== null) {
      document.querySelector('meta[name="theme-color"]').setAttribute('content', '#0d0d0d')
    }
  }
  window.activateLightMode = function () {
    document.documentElement.setAttribute('data-theme', 'light')
   if (document.querySelector('meta[name="theme-color"]') !== null) {
      document.querySelector('meta[name="theme-color"]').setAttribute('content', '#ffffff')
    }
  }
  const autoChangeMode = '1'
  const t = saveToLocal.get('theme')
  if (autoChangeMode === '1') {
    const isDarkMode = window.matchMedia('(prefers-color-scheme: dark)').matches
    const isLightMode = window.matchMedia('(prefers-color-scheme: light)').matches
    const isNotSpecified = window.matchMedia('(prefers-color-scheme: no-preference)').matches
    const hasNoSupport = !isDarkMode && !isLightMode && !isNotSpecified
    if (t === undefined) {
      if (isLightMode) activateLightMode()
      else if (isDarkMode) activateDarkMode()
      else if (isNotSpecified || hasNoSupport) {
        const now = new Date()
        const hour = now.getHours()
        const isNight = hour <= 6 || hour >= 18
        isNight ? activateDarkMode() : activateLightMode()
      }
      window.matchMedia('(prefers-color-scheme: dark)').addListener(function (e) {
        if (saveToLocal.get('theme') === undefined) {
          e.matches ? activateDarkMode() : activateLightMode()
        }
      })
    } else if (t === 'light') activateLightMode()
    else activateDarkMode()
  } else if (autoChangeMode === '2') {
    const now = new Date()
    const hour = now.getHours()
    const isNight = hour <= 6 || hour >= 18
    if (t === undefined) isNight ? activateDarkMode() : activateLightMode()
    else if (t === 'light') activateLightMode()
    else activateDarkMode()
  } else {
    if (t === 'dark') activateDarkMode()
    else if (t === 'light') activateLightMode()
  }const asideStatus = saveToLocal.get('aside-status')
if (asideStatus !== undefined) {
   if (asideStatus === 'hide') {
     document.documentElement.classList.add('hide-aside')
   } else {
     document.documentElement.classList.remove('hide-aside')
   }
}const fontSizeVal = saveToLocal.get('global-font-size')
if (fontSizeVal !== undefined) {
  document.documentElement.style.setProperty('--global-font-size', fontSizeVal + 'px')
}})()</script><meta name="generator" content="Hexo 5.3.0"></head><body><div id="loading-box"><div class="loading-left-bg"></div><div class="loading-right-bg"></div><div class="spinner-box"><div class="configure-border-1"><div class="configure-core"></div></div><div class="configure-border-2"><div class="configure-core"></div></div><div class="loading-word">Loading...</div></div></div><div id="sidebar"><div id="menu-mask"></div><div id="sidebar-menus"><div class="author-avatar"><img class="avatar-img" src="/img/avatar.png" onerror="onerror=null;src='/img/friend_404.gif'" alt="avatar"/></div><div class="site-data"><div class="data-item is-center"><div class="data-item-link"><a href="/archives/"><div class="headline">Articles</div><div class="length-num">23</div></a></div></div><div class="data-item is-center"><div class="data-item-link"><a href="/tags/"><div class="headline">Tags</div><div class="length-num">12</div></a></div></div><div class="data-item is-center"><div class="data-item-link"><a href="/categories/"><div class="headline">Categories</div><div class="length-num">3</div></a></div></div></div><hr/><div class="menus_items"><div class="menus_item"><a class="site-page" href="/"><i class="fa-fw fa fa-home"></i><span> Home</span></a></div><div class="menus_item"><a class="site-page" href="/archives/"><i class="fa-fw fa fa-archive"></i><span> Archives</span></a></div><div class="menus_item"><a class="site-page" href="/tags/"><i class="fa-fw fa fa-tags"></i><span> Tags</span></a></div><div class="menus_item"><a class="site-page" href="/categories/"><i class="fa-fw fa fa-folder-open"></i><span> Categories</span></a></div></div></div></div><div class="post" id="body-wrap"><header class="post-bg" id="page-header" style="background-image: url('https://5b0988e595225.cdn.sohucs.com/images/20190831/84729f5c5bb346208416445feb485df6.jpeg')"><nav id="nav"><span id="blog_name"><a id="site-name" href="/">Cying</a></span><div id="menus"><div class="menus_items"><div class="menus_item"><a class="site-page" href="/"><i class="fa-fw fa fa-home"></i><span> Home</span></a></div><div class="menus_item"><a class="site-page" href="/archives/"><i class="fa-fw fa fa-archive"></i><span> Archives</span></a></div><div class="menus_item"><a class="site-page" href="/tags/"><i class="fa-fw fa fa-tags"></i><span> Tags</span></a></div><div class="menus_item"><a class="site-page" href="/categories/"><i class="fa-fw fa fa-folder-open"></i><span> Categories</span></a></div></div><div id="toggle-menu"><a class="site-page"><i class="fas fa-bars fa-fw"></i></a></div></div></nav><div id="post-info"><h1 class="post-title">UML</h1><div id="post-meta"><div class="meta-firstline"><span class="post-meta-date"><i class="far fa-calendar-alt fa-fw post-meta-icon"></i><span class="post-meta-label">Created</span><time class="post-meta-date-created" datetime="2020-02-26T10:37:23.000Z" title="Created 2020-02-26 18:37:23">2020-02-26</time><span class="post-meta-separator">|</span><i class="fas fa-history fa-fw post-meta-icon"></i><span class="post-meta-label">Updated</span><time class="post-meta-date-updated" datetime="2020-02-26T10:52:40.000Z" title="Updated 2020-02-26 18:52:40">2020-02-26</time></span><span class="post-meta-categories"><span class="post-meta-separator">|</span><i class="fas fa-inbox fa-fw post-meta-icon"></i><a class="post-meta-categories" href="/categories/Blog/">Blog</a></span></div><div class="meta-secondline"><span class="post-meta-separator">|</span><span class="post-meta-wordcount"><i class="far fa-file-word fa-fw post-meta-icon"></i><span class="post-meta-label">Word count:</span><span class="word-count">519</span><span class="post-meta-separator">|</span><i class="far fa-clock fa-fw post-meta-icon"></i><span class="post-meta-label">Reading time:</span><span>1min</span></span><span class="post-meta-separator">|</span><span class="post-meta-pv-cv"><i class="far fa-eye fa-fw post-meta-icon"></i><span class="post-meta-label">Post View:</span><span id="busuanzi_value_page_pv"></span></span></div></div></div></header><main class="layout" id="content-inner"><div id="post"><article class="post-content" id="article-container"><html><head></head><body><h2 id="一、Why-UML"><a href="#一、Why-UML" class="headerlink" title="一、Why UML"></a>一、Why UML</h2><p><code>UML (Unified Modeling Language - 统一建模语言)</code> ，是一种用来对软件密集系统进行 <strong>可视化建模</strong> 的语言，<code>UML</code> 的定义包括 <code>UML</code> 语义和 <code>UML</code> 表示法两个元素。</p>
<p><code>UML</code> 的目标是以 <strong>面向对象图</strong> 的方式来描述任何类型的系统，具有很宽的应用领域，包含十种图</p>
<p><a href="https://wiki.hk.wjbk.site/wiki/UML" target="_blank" rel="noopener">点击跳转至Wiki解释</a></p>
<h2 id="二、What-is-UML-Class-Diagram"><a href="#二、What-is-UML-Class-Diagram" class="headerlink" title="二、What is UML Class Diagram"></a>二、What is UML Class Diagram</h2><p><code>Class Diagram</code> ：类图</p>
<p>类图在 <code>UML</code> 的十个图中占据了一个相当重要的地位。<code>James Rumbaugh</code> 对类的定义是：”类是具有相似结构、行为和关系的一组对象的描述符。”，类是面向对象系统中最重要的构造块。而类图显示了一组类、接口、协作以及他们之间的关系。</p>
<p><a href="[https://baike.baidu.com/item/UML%E7%B1%BB%E5%9B%BE/6842152?fr=aladdin](https://baike.baidu.com/item/UML类图/6842152?fr=aladdin)">点击跳转至Baidu解释</a></p>
<h2 id="三、怎么画-UML-类图"><a href="#三、怎么画-UML-类图" class="headerlink" title="三、怎么画 UML 类图"></a>三、怎么画 UML 类图</h2><p><a target="_blank" rel="noopener" href="https://img-blog.csdnimg.cn/2020022618480379.png?x-oss-process=image/watermark,type_ZmFuZ3poZW5naGVpdGk,shadow_10,text_aHR0cHM6Ly9ibG9nLmNzZG4ubmV0L0N5aW5nSw==,size_16,color_FFFFFF,t_70" data-fancybox="group" data-caption="在这里插入图片描述" class="fancybox"><img alt="在这里插入图片描述" title="在这里插入图片描述" data-src="https://img-blog.csdnimg.cn/2020022618480379.png?x-oss-process=image/watermark,type_ZmFuZ3poZW5naGVpdGk,shadow_10,text_aHR0cHM6Ly9ibG9nLmNzZG4ubmV0L0N5aW5nSw==,size_16,color_FFFFFF,t_70" class="lazyload"></a></p>
<ul>
<li><strong>属性和方法前面的 +、-、# 分别代表 public、private、protect</strong></li>
<li><strong>方法名/属性名写在冒号前面，类型/返回值类型写在冒号后面</strong></li>
</ul>
<h3 id="3-1-Generalization"><a href="#3-1-Generalization" class="headerlink" title="3.1.Generalization"></a>3.1.Generalization</h3><p><code>Generalization</code>：泛化、继承</p>
<ul>
<li><strong>Direction</strong> ：B to A</li>
<li><strong>Express</strong>：实线 + 三角形</li>
<li><strong>Relational</strong>：B 继承 A<br><a target="_blank" rel="noopener" href="https://img-blog.csdnimg.cn/20200226184823947.png#pic_center" data-fancybox="group" data-caption="在这里插入图片描述" class="fancybox"><img alt="在这里插入图片描述" title="在这里插入图片描述" data-src="https://img-blog.csdnimg.cn/20200226184823947.png#pic_center" class="lazyload"></a></li>
</ul>
<hr>
<h3 id="3-2-Realization"><a href="#3-2-Realization" class="headerlink" title="3.2.Realization"></a>3.2.Realization</h3><p><code>Realization</code>：实现</p>
<ul>
<li><strong>Direction</strong>：B to A</li>
<li><strong>Express</strong>：虚线 + 三角形</li>
<li><strong>Relational</strong>：B 实现 A<br><a target="_blank" rel="noopener" href="https://img-blog.csdnimg.cn/20200226184906429.png#pic_center" data-fancybox="group" data-caption="在这里插入图片描述" class="fancybox"><img alt="在这里插入图片描述" title="在这里插入图片描述" data-src="https://img-blog.csdnimg.cn/20200226184906429.png#pic_center" class="lazyload"></a></li>
</ul>
<hr>
<h3 id="3-3-Dependency"><a href="#3-3-Dependency" class="headerlink" title="3.3.Dependency"></a>3.3.Dependency</h3><p><code>Dependency</code>：依赖</p>
<ul>
<li><strong>Direction</strong>：B to A</li>
<li><strong>Express</strong>：虚线 + 箭头</li>
<li><strong>Relational</strong>：即，A 使用到了 B，比如在 A 中某个方法中有 A 的对象<br><a target="_blank" rel="noopener" href="https://img-blog.csdnimg.cn/20200226185014922.png#pic_center" data-fancybox="group" data-caption="在这里插入图片描述" class="fancybox"><img alt="在这里插入图片描述" title="在这里插入图片描述" data-src="https://img-blog.csdnimg.cn/20200226185014922.png#pic_center" class="lazyload"></a></li>
</ul>
<hr>
<h3 id="3-4-Association"><a href="#3-4-Association" class="headerlink" title="3.4.Association"></a>3.4.Association</h3><p><code>association</code>：关联</p>
<ul>
<li><strong>Direction</strong>：B to A</li>
<li><strong>Express</strong>：实线 + 箭头</li>
<li><strong>Relation</strong>：在 B 中有 A 类的对象属性<br><a target="_blank" rel="noopener" href="https://img-blog.csdnimg.cn/20200226185038596.png#pic_center" data-fancybox="group" data-caption="在这里插入图片描述" class="fancybox"><img alt="在这里插入图片描述" title="在这里插入图片描述" data-src="https://img-blog.csdnimg.cn/20200226185038596.png#pic_center" class="lazyload"></a></li>
</ul>
<hr>
<h3 id="3-5-Aggregation"><a href="#3-5-Aggregation" class="headerlink" title="3.5.Aggregation"></a>3.5.Aggregation</h3><p><code>aggregation</code>：聚合        </p>
<ul>
<li><p><strong>Direction</strong>：B to A</p>
</li>
<li><p><strong>Express</strong>：空心菱形（被聚合的一方） + 实线 + 箭头</p>
</li>
<li><p><strong>Relation</strong>：表示一种弱拥有的关系：<code>has-a</code>，意思是有一个。即 A 中拥有 B 类的对象，但 A 里不是一定要有这个对象，比如手机上可以有手机壳，但并不是必须要有<br><a target="_blank" rel="noopener" href="https://img-blog.csdnimg.cn/2020022618510490.png#pic_center" data-fancybox="group" data-caption="在这里插入图片描述" class="fancybox"><img alt="在这里插入图片描述" title="在这里插入图片描述" data-src="https://img-blog.csdnimg.cn/2020022618510490.png#pic_center" class="lazyload"></a></p>
</li>
</ul>
<hr>
<h3 id="3-6-Composition"><a href="#3-6-Composition" class="headerlink" title="3.6.Composition"></a>3.6.Composition</h3><p><code>composition</code>：组合</p>
<ul>
<li><strong>Direction</strong>：B to A</li>
<li><strong>Express</strong>：实心菱形（被组合的一方） + 实线 + 箭头</li>
<li><strong>Relation</strong>：表示一种强拥有的关系：<code>part-of</code>，意思是一部分为。即 A 中拥有 B 类的队形，而且不能失去这个对象，比如手机上必须要有一个处理器<br><a target="_blank" rel="noopener" href="https://img-blog.csdnimg.cn/20200226185128850.png#pic_center" data-fancybox="group" data-caption="在这里插入图片描述" class="fancybox"><img alt="在这里插入图片描述" title="在这里插入图片描述" data-src="https://img-blog.csdnimg.cn/20200226185128850.png#pic_center" class="lazyload"></a></li>
</ul>
</body></html></article><div class="post-copyright"><div class="post-copyright__author"><span class="post-copyright-meta">Author: </span><span class="post-copyright-info"><a href="mailto:undefined">Cying-承影</a></span></div><div class="post-copyright__type"><span class="post-copyright-meta">Link: </span><span class="post-copyright-info"><a href="http://cyingk.github.io/2020/02/26/UML/">http://cyingk.github.io/2020/02/26/UML/</a></span></div><div class="post-copyright__notice"><span class="post-copyright-meta">Copyright Notice: </span><span class="post-copyright-info">All articles in this blog are licensed under <a target="_blank" rel="noopener" href="https://creativecommons.org/licenses/by-nc-sa/4.0/">CC BY-NC-SA 4.0</a> unless stating additionally.</span></div></div><div class="tag_share"><div class="post-meta__tag-list"><a class="post-meta__tags" href="/tags/Java/">Java</a></div><div class="post_share"></div></div><nav class="pagination-post" id="pagination"><div class="prev-post pull-left"><a href="/2020/03/15/Gossip/"><img class="prev-cover" src="https://img-blog.csdnimg.cn/2020031523402253.jpg" onerror="onerror=null;src='/img/404.jpg'" alt="cover of previous post"><div class="pagination-info"><div class="label">Previous Post</div><div class="prev_info">Summary_200315</div></div></a></div><div class="next-post pull-right"><a href="/2020/02/20/Mybatis/"><img class="next-cover" src="https://ss1.bdstatic.com/70cFvXSh_Q1YnxGkpoWK1HF6hhy/it/u=575314515,4268715674&amp;fm=26&amp;gp=0.jpg" onerror="onerror=null;src='/img/404.jpg'" alt="cover of next post"><div class="pagination-info"><div class="label">Next Post</div><div class="next_info">MyBatis</div></div></a></div></nav><div class="relatedPosts"><div class="headline"><i class="fas fa-thumbs-up fa-fw"></i><span> Related Articles</span></div><div class="relatedPosts-list"><div><a href="/2020/01/16/Design_Pattern/" title="Design Pattern"><img class="cover" src="https://www.runoob.com/wp-content/uploads/2014/08/the-relationship-between-design-patterns.jpg" alt="cover"><div class="content is-center"><div class="date"><i class="far fa-calendar-alt fa-fw"></i> 2020-01-16</div><div class="title">Design Pattern</div></div></a></div><div><a href="/2019/12/13/SQL_To_Java/" title="JDBC"><img class="cover" src="https://img-blog.csdnimg.cn/20191213203223906.png" alt="cover"><div class="content is-center"><div class="date"><i class="far fa-calendar-alt fa-fw"></i> 2019-12-13</div><div class="title">JDBC</div></div></a></div></div></div></div><div class="aside-content" id="aside-content"><div class="sticky_layout"><div class="card-widget" id="card-toc"><div class="item-headline"><i class="fas fa-stream"></i><span>Catalog</span></div><div class="toc-content"><ol class="toc"><li class="toc-item toc-level-2"><a class="toc-link" href="#%E4%B8%80%E3%80%81Why-UML"><span class="toc-number">1.</span> <span class="toc-text">一、Why UML</span></a></li><li class="toc-item toc-level-2"><a class="toc-link" href="#%E4%BA%8C%E3%80%81What-is-UML-Class-Diagram"><span class="toc-number">2.</span> <span class="toc-text">二、What is UML Class Diagram</span></a></li><li class="toc-item toc-level-2"><a class="toc-link" href="#%E4%B8%89%E3%80%81%E6%80%8E%E4%B9%88%E7%94%BB-UML-%E7%B1%BB%E5%9B%BE"><span class="toc-number">3.</span> <span class="toc-text">三、怎么画 UML 类图</span></a><ol class="toc-child"><li class="toc-item toc-level-3"><a class="toc-link" href="#3-1-Generalization"><span class="toc-number">3.1.</span> <span class="toc-text">3.1.Generalization</span></a></li><li class="toc-item toc-level-3"><a class="toc-link" href="#3-2-Realization"><span class="toc-number">3.2.</span> <span class="toc-text">3.2.Realization</span></a></li><li class="toc-item toc-level-3"><a class="toc-link" href="#3-3-Dependency"><span class="toc-number">3.3.</span> <span class="toc-text">3.3.Dependency</span></a></li><li class="toc-item toc-level-3"><a class="toc-link" href="#3-4-Association"><span class="toc-number">3.4.</span> <span class="toc-text">3.4.Association</span></a></li><li class="toc-item toc-level-3"><a class="toc-link" href="#3-5-Aggregation"><span class="toc-number">3.5.</span> <span class="toc-text">3.5.Aggregation</span></a></li><li class="toc-item toc-level-3"><a class="toc-link" href="#3-6-Composition"><span class="toc-number">3.6.</span> <span class="toc-text">3.6.Composition</span></a></li></ol></li></ol></div></div></div></div></main><footer id="footer"><div id="footer-wrap"><div class="footer_custom_text">却道天凉好个秋</div></div></footer></div><div id="rightside"><div id="rightside-config-hide"><button id="readmode" type="button" title="Read Mode"><i class="fas fa-book-open"></i></button><button id="font-plus" type="button" title="Increase font size"><i class="fas fa-plus"></i></button><button id="font-minus" type="button" title="Decrease font size"><i class="fas fa-minus"></i></button><button id="darkmode" type="button" title="Switch Between Light And Dark Mode"><i class="fas fa-adjust"></i></button><button id="hide-aside-btn" type="button" title="Toggle between single-column and double-column"><i class="fas fa-arrows-alt-h"></i></button></div><div id="rightside-config-show"><button id="rightside_config" type="button" title="Setting"><i class="fas fa-cog fa-spin"></i></button><button class="close" id="mobile-toc-button" type="button" title="Table Of Contents"><i class="fas fa-list-ul"></i></button><button id="go-up" type="button" title="Back To Top"><i class="fas fa-arrow-up"></i></button></div></div><div><script src="/js/utils.js"></script><script src="/js/main.js"></script><script src="https://cdn.jsdelivr.net/npm/instant.page/instantpage.min.js" type="module"></script><script src="https://cdn.jsdelivr.net/npm/node-snackbar/dist/snackbar.min.js"></script><script>function panguFn () {
  if (typeof pangu === 'object') pangu.autoSpacingPage()
  else {
    getScript('https://cdn.jsdelivr.net/npm/pangu/dist/browser/pangu.min.js')
      .then(() => {
        pangu.autoSpacingPage()
      })
  }
}

function panguInit () {
  if (false){
    GLOBAL_CONFIG_SITE.isPost && panguFn()
  } else {
    panguFn()
  }
}

document.addEventListener('DOMContentLoaded', panguInit)</script><script>var preloader = {
  endLoading: () => {
    document.body.style.overflow = 'auto';
    document.getElementById('loading-box').classList.add("loaded")
  },
  initLoading: () => {
    document.body.style.overflow = '';
    document.getElementById('loading-box').classList.remove("loaded")

  }
}
window.addEventListener('load',preloader.endLoading())</script><div class="js-pjax"><script>if (document.getElementsByClassName('mermaid').length) {
  if (window.mermaidJsLoad) mermaid.init()
  else {
    getScript('https://cdn.jsdelivr.net/npm/mermaid/dist/mermaid.min.js').then(() => {
      window.mermaidJsLoad = true
      mermaid.initialize({
        theme: 'default',
      })
      false && mermaid.init()
    })
  }
}</script></div><canvas class="fireworks" mobile="false"></canvas><script src="https://cdn.jsdelivr.net/npm/butterfly-extsrc@1/dist/fireworks.min.js"></script><script defer="defer" id="fluttering_ribbon" mobile="false" src="https://cdn.jsdelivr.net/npm/butterfly-extsrc@1/dist/canvas-fluttering-ribbon.min.js"></script><script async data-pjax src="//busuanzi.ibruce.info/busuanzi/2.3/busuanzi.pure.mini.js"></script></div></body></html>